Conversation
Contributor
Author
|
@Ad96el please ignore the CI error, it is a consequence of the shitty benchmarking logic, which I plan to get rid of in the upcoming PR. |
Ad96el
reviewed
Mar 5, 2024
Contributor
Ad96el
left a comment
There was a problem hiding this comment.
LGTM overall. Nice job 👏
Some minor comments
crates/kilt-dip-primitives/src/merkle/v0/dip_subject_state/mod.rs
Outdated
Show resolved
Hide resolved
crates/kilt-dip-primitives/src/merkle/v0/dip_subject_state/tests.rs
Outdated
Show resolved
Hide resolved
crates/kilt-dip-primitives/src/merkle/v0/provider_state/tests.rs
Outdated
Show resolved
Hide resolved
crates/kilt-dip-primitives/src/merkle/v0/provider_state/tests.rs
Outdated
Show resolved
Hide resolved
3cd2292 to
740c79d
Compare
Ad96el
reviewed
Mar 7, 2024
Contributor
|
Last picky comment: In the crates/kilt-dip-primitives, there is the module |
Fixes https://github.com/KILTprotocol/ticket/issues/3104, based on top of #611. It fixes the logic for the `dip-consumer` pallet, by delegating the generation of a proof worst case to the proof verifier, which must make sure the proof is indeed the one that requires the most weight to verify, and that it verifies successfully. This also means that each consumer runtime is responsible to implement this method, as there cannot be a "universal" worst proof, as that depends on the use case. The pallet benchmarking logic is now generic enough to make this possible and flexible ✨✨✨
Ad96el
pushed a commit
that referenced
this pull request
Apr 2, 2024
Partially fixes https://github.com/KILTprotocol/ticket/issues/2562. Adds unit tests for the verifier components (components tested are shown in the checklist below). It also splits up the proof verification logic into multiple files, split by when those checks are performed. Check the `crates/kilt-dip-primitives/src/merkle/v0/` folder for more details. It addresses an open comment in the DIP refactoring PR: #602 (comment). ## Elements to add tests for - [x] `pallet-dip-consumer` - [x] `pallet-relay-store` - [x] `ProofVerifier` - [x] Merge #612 - [x] Merge #613
ntn-x2
added a commit
that referenced
this pull request
Apr 4, 2024
Partially fixes https://github.com/KILTprotocol/ticket/issues/2562. Adds unit tests for the verifier components (components tested are shown in the checklist below). It also splits up the proof verification logic into multiple files, split by when those checks are performed. Check the `crates/kilt-dip-primitives/src/merkle/v0/` folder for more details. It addresses an open comment in the DIP refactoring PR: #602 (comment). ## Elements to add tests for - [x] `pallet-dip-consumer` - [x] `pallet-relay-store` - [x] `ProofVerifier` - [x] Merge #612 - [x] Merge #613
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Partially fixes https://github.com/KILTprotocol/ticket/issues/2562.
Adds unit tests for the verifier components (components tested are shown in the checklist below).
It also splits up the proof verification logic into multiple files, split by when those checks are performed. Check the
crates/kilt-dip-primitives/src/merkle/v0/folder for more details. It addresses an open comment in the DIP refactoring PR: #602 (comment).Elements to add tests for
pallet-dip-consumerpallet-relay-storeProofVerifier